import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home.vue'
import Overview from '../views/Overview.vue'

import Login from '../views/Login.vue'
import Background from '../views/Background.vue'
import Users from '../views/user/User.vue'
import Rights from '../views/power/Rights.vue'
import Roles from '../views/power/Roles.vue'

import Building from '../views/Building.vue' 
import Floor_15 from '../components/Building/15f.vue'
import Floor_1 from '../components/Building/1f.vue'

import Test from '../components/Building/Panorama.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    component: Home,
  },
  {
    path: '/home',
    component: Home
  },
  {
    path: '/overview',
    component: Overview
  },
  {
    path: '/back',
    component: Background,
    children:[
      { path: '/users', component: Users},
      { path: '/rights', component: Rights},
      { path: '/roles', component: Roles},
    ]
  },
  // { path: '/login', component: Login },
  {
    path: '/building',
    component: Building,
  },
  {
    path: '/Floor_15',
    component: Floor_15
  },
  {
    path: '/Floor_1',
    component: Floor_1
  },
  {
    path: '/test',
    component: Test
  },

]

const router = new VueRouter({
  // mode: 'history',
  routes
})

export default router
